package com.fortune.dao;
import com.fortune.vo.dStoreIn.StorageDetails;
import com.fortune.vo.dStoreOut.DStorePro;
import org.apache.ibatis.annotations.Param;

import com.fortune.dto.in.dStoreOut.DStoreOutListDto;
import com.fortune.entity.DUserInfo;
import com.fortune.vo.dStoreOut.DStoreOutInfo;
import com.fortune.vo.dStoreOut.DStoreOutInfoDetail;

import java.util.List;

public interface DStoreOutDao {
    /**
     *查询出库单列表
     * @param companyId
     * @param dStoreOutListDto
     * @return
     */
    List<DStoreOutInfo> queryDStoreOutList(@Param("dUserInfo")DUserInfo dUserInfo,@Param("dStoreOutListDto") DStoreOutListDto dStoreOutListDto,@Param("dateStart")String dateStart,@Param("dateEnd")String dateEnd);

    /**
     *查询出库单列表个数
     * @param companyId
     * @param dStoreOutListDto
     * @return
     */
    int queryDStoreOutListCount(@Param("dUserInfo")DUserInfo dUserInfo,@Param("dStoreOutListDto") DStoreOutListDto dStoreOutListDto);

    List<DStorePro> findListDetail(@Param("id")String id, @Param("did")String did);

    /**
     *出库单详情
     * @param companyId
     * @param id
     * @return
     */
    DStoreOutInfoDetail queryDStoreOutInfoDetail(@Param("dUserInfo")DUserInfo dUserInfo, @Param("id") String id);
    /**
     * 确认发货
     * @param companyId
     * @param id
     * @return
     */
    int updateType(@Param("dUserInfo")DUserInfo dUserInfo, @Param("id") String id);

    List<StorageDetails> findDetails(@Param("did")String did,@Param("id")String id);

    int insertStorageProductStockDetail(@Param("mid")String mid,@Param("did")String did,@Param("info")StorageDetails info,@Param("order")int order);

    List<DStorePro> findListDidDriver(@Param("did")String did);

    List<DStorePro> findListDidClient(@Param("did")String did);
}
